﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Freetour.Application.Services.Membership;
using Freetour.Application.Services.Membership.Implements;

namespace Freetour.Application.Services
{
    public class ServicesFactory
    {
        private static ServicesFactory instance;

        private ServicesFactory()
        {
        }

        public static ServicesFactory Instance
        {
            get 
            {
                if (instance == null)
                {
                    instance = new ServicesFactory();
                }
                return instance; 
            }
        }

        private IMembershipServices _membership;

        public IMembershipServices Membership
        {
            get 
            {
                if (_membership == null)
                {
                    _membership = new MembershipServices();
                }

                return _membership as IMembershipServices;
            }
        }
    }
}
